export default class di extends Laya.Script {

    constructor() { 
        super(); 
        this.speed=20;

        // 更多参数说明请访问: https://ldc2.layabox.com/doc/?nav=zh-as-2-4-0
    }
        onAwake(){
        }
        Init(sign){
            this.sign=sign;
        }
        onUpdate(){
            this.owner.y+=this.speed;
        }
        onTriggerExit(other){
            if(other.label=="dibian"){
                this.owner.removeSelf();
            Laya.Pool.recover(this.sign,this.owner);
            }
            if(other.label=="zidan"){
                this.owner.removeSelf();
                Laya.SoundManager.playSound("res/Sounds/di.WAV",1);
            Laya.Pool.recover(this.sign,this.owner);
            }
            }
}